// 自动全局注册组件

import Vue from 'vue'

const requireComponents = require.context('@/components', true, /\.vue$/)
requireComponents.keys().forEach((fileName) => {
  const componentConfig = requireComponents(fileName)
  const componentName = componentConfig.default.name
  // console.log('全局注册==>', componentConfig )
  Vue.component(componentName, componentConfig.default || componentConfig)
})
